﻿#include "CThread.h"
#include <string.h>
#include <process.h>

static int run(struct _cthread_* th, void(*entry)(void *), void* param) {
	_beginthread(entry, 0, param);
	return 0;
}

int construct_thread(CThread* th) {
	memset(th, 0, sizeof(*th));
	th->run = run;
	return 0;
}